﻿namespace ACCOUNTING
{
    using ACCOUNTING.LVY.Business;
    using ACCOUNTING.My.Resources;
    using C1.Win.C1Input;
    using Microsoft.VisualBasic.CompilerServices;
    using System;
    using System.Collections.Generic;
    using System.ComponentModel;
    using System.Diagnostics;
    using System.Drawing;
    using System.Runtime.CompilerServices;
    using System.Windows.Forms;

    [DesignerGenerated]
    public class Frm_ChiPhiTraTruoc : Form
    {
        private static List<WeakReference> __ENCList = new List<WeakReference>();
        [AccessedThroughProperty("AdvBoPhanCo")]
        private ADVList _AdvBoPhanCo;
        [AccessedThroughProperty("AdvBoPhanNo")]
        private ADVList _AdvBoPhanNo;
        [AccessedThroughProperty("advHopDongCo")]
        private ADVList _advHopDongCo;
        [AccessedThroughProperty("AdvHopDongNo")]
        private ADVList _AdvHopDongNo;
        [AccessedThroughProperty("advSanPhamCo")]
        private ADVList _advSanPhamCo;
        [AccessedThroughProperty("AdvSanPhamNo")]
        private ADVList _AdvSanPhamNo;
        [AccessedThroughProperty("AdvTaiKhoanCo")]
        private ADVAccount _AdvTaiKhoanCo;
        [AccessedThroughProperty("AdvTaiKhoanNo")]
        private ADVAccount _AdvTaiKhoanNo;
        [AccessedThroughProperty("CmdCancel")]
        private Button _CmdCancel;
        [AccessedThroughProperty("CmdOK")]
        private Button _CmdOK;
        [AccessedThroughProperty("GroupBox1")]
        private GroupBox _GroupBox1;
        [AccessedThroughProperty("GroupBox2")]
        private GroupBox _GroupBox2;
        [AccessedThroughProperty("GroupBox3")]
        private GroupBox _GroupBox3;
        [AccessedThroughProperty("GroupBox4")]
        private GroupBox _GroupBox4;
        [AccessedThroughProperty("Label1")]
        private Label _Label1;
        [AccessedThroughProperty("Label10")]
        private Label _Label10;
        [AccessedThroughProperty("Label11")]
        private Label _Label11;
        [AccessedThroughProperty("Label12")]
        private Label _Label12;
        [AccessedThroughProperty("Label13")]
        private Label _Label13;
        [AccessedThroughProperty("Label14")]
        private Label _Label14;
        [AccessedThroughProperty("Label16")]
        private Label _Label16;
        [AccessedThroughProperty("Label17")]
        private Label _Label17;
        [AccessedThroughProperty("Label2")]
        private Label _Label2;
        [AccessedThroughProperty("Label23")]
        private Label _Label23;
        [AccessedThroughProperty("Label3")]
        private Label _Label3;
        [AccessedThroughProperty("Label4")]
        private Label _Label4;
        [AccessedThroughProperty("Label5")]
        private Label _Label5;
        [AccessedThroughProperty("Label6")]
        private Label _Label6;
        [AccessedThroughProperty("Label7")]
        private Label _Label7;
        [AccessedThroughProperty("Label8")]
        private Label _Label8;
        [AccessedThroughProperty("Label9")]
        private Label _Label9;
        [AccessedThroughProperty("txtConLai")]
        private C1NumericEdit _txtConLai;
        [AccessedThroughProperty("txtDaPhanBo")]
        private C1NumericEdit _txtDaPhanBo;
        [AccessedThroughProperty("TxtDienGiai")]
        private TextBox _TxtDienGiai;
        [AccessedThroughProperty("TxtNgayChungTu")]
        private DateTimePicker _TxtNgayChungTu;
        [AccessedThroughProperty("TxtSoChungTu")]
        private TextBox _TxtSoChungTu;
        [AccessedThroughProperty("TxtSoPhatSinh")]
        private C1NumericEdit _TxtSoPhatSinh;
        [AccessedThroughProperty("TxtThangBatDau")]
        private MaskedTextBox _TxtThangBatDau;
        [AccessedThroughProperty("TxtTriGiaPhanBo")]
        private C1NumericEdit _TxtTriGiaPhanBo;
        [AccessedThroughProperty("updSoThangPhanBo")]
        private NumericUpDown _updSoThangPhanBo;
        public string cFrmKhoa;
        private string cFrmKhoaChungTu;
        private string cFrmKhoaTaiKhoan;
        private IContainer components;
        private GLDinhNghiaPhanBo objPB;

        public Frm_ChiPhiTraTruoc()
        {
            base.Load += new EventHandler(this.Frm_ChiPhiTraTruoc_Load);
            List<WeakReference> list = __ENCList;
            lock (list)
            {
                __ENCList.Add(new WeakReference(this));
            }
            this.cFrmKhoa = "";
            this.cFrmKhoaChungTu = "";
            this.cFrmKhoaTaiKhoan = "";
            this.objPB = new GLDinhNghiaPhanBo();
            this.InitializeComponent();
        }

        public bool CheckIvalid()
        {
            if (this.TxtThangBatDau.Text == "__/____")
            {
                LVYModule.ShowWarning(modGeneral.Tranlated("Bạn phải nhập th\x00e1ng bắt đầu ph\x00e2n bổ!", ""));
                this.TxtThangBatDau.Focus();
                return false;
            }
            if (decimal.Compare(this.updSoThangPhanBo.Value, decimal.Zero) == 0)
            {
                LVYModule.ShowWarning(modGeneral.Tranlated("Bạn phải nhập số th\x00e1ng ph\x00e2n bổ!", ""));
                this.updSoThangPhanBo.Focus();
                return false;
            }
            if (this.AdvTaiKhoanNo.Value.Trim() == "")
            {
                LVYModule.ShowWarning(modGeneral.Tranlated("Bạn phải nhập t\x00e0i khoản ph\x00e2n bổ!", ""));
                this.AdvTaiKhoanNo.Focus();
                return false;
            }
            return true;
        }

        private void CmdCancel_Click(object sender, EventArgs e)
        {
            this.Dispose();
        }

        private void CmdOK_Click(object sender, EventArgs e)
        {
            if (this.CheckIvalid())
            {
                if (LVYModule.ReturnIfNull(this.cFrmKhoa, "", modGeneral.TypeOfValue.Nothing).ToString().Trim() == "")
                {
                    this.cFrmKhoa = modGeneral.CreatKey("GL_DinhNghiaPhanBoChiPhiTraTruoc", 15, "");
                }
                GLDinhNghiaPhanBo objPB = this.objPB;
                objPB.Khoa = this.cFrmKhoa;
                objPB.KhoaChungTu = Conversions.ToString(this.TxtSoChungTu.Tag);
                objPB.SoChungTu = this.TxtSoChungTu.Text;
                objPB.NgayChungTu = LVYModule.Date2Char(this.TxtNgayChungTu.Text);
                objPB.KhoaTaiKhoan = this.AdvTaiKhoanCo.Value;
                objPB.SoPhatSinh = Conversions.ToDouble(this.TxtSoPhatSinh.Value);
                objPB.DienGiai = this.TxtDienGiai.Text.Trim();
                objPB.ThangBatDauPhanBo = LVYModule.sRight(this.TxtThangBatDau.Text, 4) + LVYModule.sLeft(this.TxtThangBatDau.Text, 2);
                objPB.SoThangPhanBo = Convert.ToInt32(this.updSoThangPhanBo.Value);
                objPB.DaPhanBo = Conversions.ToDouble(this.txtDaPhanBo.Value);
                objPB.ConLai = Conversions.ToDouble(this.txtConLai.Value);
                objPB.TriGiaPhanBo = Conversions.ToDouble(this.TxtTriGiaPhanBo.Value);
                objPB.KhoaBoPhanCo = this.AdvBoPhanCo.Value;
                objPB.KhoaSanPhamCo = this.advSanPhamCo.Value;
                objPB.KhoaHopDongCo = this.advHopDongCo.Value;
                objPB.KhoaTaiKhoanNo = this.AdvTaiKhoanNo.Value;
                objPB.KhoaBoPhanNo = this.AdvBoPhanNo.Value;
                objPB.KhoaSanPhamNo = this.AdvSanPhamNo.Value;
                objPB.KhoaHopDongNo = this.AdvHopDongNo.Value;
                objPB.LoaiTien = modGeneral.H_CURRENCY;
                objPB.NgungPhanBo = 0;
                objPB.TyGia = 1.0;
                objPB.KhoaDonVi = modGeneral.H_CLIENT;
                objPB.Save();
                objPB = null;
                this.Dispose();
            }
        }

        [DebuggerNonUserCode]
        protected override void Dispose(bool disposing)
        {
            if (disposing && (this.components != null))
            {
                this.components.Dispose();
            }
            base.Dispose(disposing);
        }

        public void FormatNumber()
        {
            LVYModule.advFormatNumber(this.TxtSoPhatSinh, modGeneral.H_FORMATNUMBER);
            LVYModule.advFormatNumber(this.txtDaPhanBo, modGeneral.H_FORMATNUMBER);
            LVYModule.advFormatNumber(this.txtConLai, modGeneral.H_FORMATNUMBER);
            LVYModule.advFormatNumber(this.TxtTriGiaPhanBo, modGeneral.H_FORMATNUMBER);
        }

        private void Frm_ChiPhiTraTruoc_Load(object sender, EventArgs e)
        {
            if (LVYModule.ReturnIfNull(this.cFrmKhoa, "", modGeneral.TypeOfValue.Nothing).ToString().Trim() != "")
            {
                this.LoadData(this.cFrmKhoa);
            }
            this.FormatNumber();
        }

        [DebuggerStepThrough]
        private void InitializeComponent()
        {
            ComponentResourceManager manager = new ComponentResourceManager(typeof(Frm_ChiPhiTraTruoc));
            this.GroupBox3 = new GroupBox();
            this.txtDaPhanBo = new C1NumericEdit();
            this.updSoThangPhanBo = new NumericUpDown();
            this.GroupBox2 = new GroupBox();
            this.Label2 = new Label();
            this.advHopDongCo = new ADVList();
            this.advSanPhamCo = new ADVList();
            this.AdvBoPhanCo = new ADVList();
            this.Label3 = new Label();
            this.Label4 = new Label();
            this.Label5 = new Label();
            this.AdvTaiKhoanCo = new ADVAccount();
            this.GroupBox1 = new GroupBox();
            this.Label1 = new Label();
            this.AdvHopDongNo = new ADVList();
            this.AdvSanPhamNo = new ADVList();
            this.AdvBoPhanNo = new ADVList();
            this.Label8 = new Label();
            this.Label7 = new Label();
            this.Label6 = new Label();
            this.AdvTaiKhoanNo = new ADVAccount();
            this.Label9 = new Label();
            this.TxtTriGiaPhanBo = new C1NumericEdit();
            this.Label23 = new Label();
            this.Label12 = new Label();
            this.txtConLai = new C1NumericEdit();
            this.Label11 = new Label();
            this.TxtThangBatDau = new MaskedTextBox();
            this.Label10 = new Label();
            this.GroupBox4 = new GroupBox();
            this.TxtDienGiai = new TextBox();
            this.Label17 = new Label();
            this.TxtNgayChungTu = new DateTimePicker();
            this.TxtSoChungTu = new TextBox();
            this.Label13 = new Label();
            this.TxtSoPhatSinh = new C1NumericEdit();
            this.Label14 = new Label();
            this.Label16 = new Label();
            this.CmdCancel = new Button();
            this.CmdOK = new Button();
            this.GroupBox3.SuspendLayout();
            ((ISupportInitialize) this.txtDaPhanBo).BeginInit();
            this.updSoThangPhanBo.BeginInit();
            this.GroupBox2.SuspendLayout();
            this.GroupBox1.SuspendLayout();
            ((ISupportInitialize) this.TxtTriGiaPhanBo).BeginInit();
            ((ISupportInitialize) this.txtConLai).BeginInit();
            this.GroupBox4.SuspendLayout();
            ((ISupportInitialize) this.TxtSoPhatSinh).BeginInit();
            this.SuspendLayout();
            this.GroupBox3.BackColor = Color.Transparent;
            this.GroupBox3.Controls.Add(this.txtDaPhanBo);
            this.GroupBox3.Controls.Add(this.updSoThangPhanBo);
            this.GroupBox3.Controls.Add(this.GroupBox2);
            this.GroupBox3.Controls.Add(this.GroupBox1);
            this.GroupBox3.Controls.Add(this.Label9);
            this.GroupBox3.Controls.Add(this.TxtTriGiaPhanBo);
            this.GroupBox3.Controls.Add(this.Label23);
            this.GroupBox3.Controls.Add(this.Label12);
            this.GroupBox3.Controls.Add(this.txtConLai);
            this.GroupBox3.Controls.Add(this.Label11);
            this.GroupBox3.Controls.Add(this.TxtThangBatDau);
            this.GroupBox3.Controls.Add(this.Label10);
            Point point = new Point(4, 0x6d);
            this.GroupBox3.Location = point;
            this.GroupBox3.Name = "GroupBox3";
            Size size = new Size(0x288, 0xfb);
            this.GroupBox3.Size = size;
            this.GroupBox3.TabIndex = 2;
            this.GroupBox3.TabStop = false;
            this.GroupBox3.Text = "Th\x00f4ng tin ph\x00e2n bổ";
            this.txtDaPhanBo.FormatType = FormatTypeEnum.StandardNumber;
            point = new Point(0x60, 0x40);
            this.txtDaPhanBo.Location = point;
            this.txtDaPhanBo.Name = "txtDaPhanBo";
            size = new Size(0x6d, 20);
            this.txtDaPhanBo.Size = size;
            this.txtDaPhanBo.TabIndex = 0x74;
            this.txtDaPhanBo.Tag = null;
            this.txtDaPhanBo.TextAlign = HorizontalAlignment.Right;
            this.txtDaPhanBo.VisibleButtons = DropDownControlButtonFlags.None;
            point = new Point(0x124, 0x27);
            this.updSoThangPhanBo.Location = point;
            this.updSoThangPhanBo.Name = "updSoThangPhanBo";
            size = new Size(0x40, 20);
            this.updSoThangPhanBo.Size = size;
            this.updSoThangPhanBo.TabIndex = 0x73;
            this.GroupBox2.Controls.Add(this.Label2);
            this.GroupBox2.Controls.Add(this.advHopDongCo);
            this.GroupBox2.Controls.Add(this.advSanPhamCo);
            this.GroupBox2.Controls.Add(this.AdvBoPhanCo);
            this.GroupBox2.Controls.Add(this.Label3);
            this.GroupBox2.Controls.Add(this.Label4);
            this.GroupBox2.Controls.Add(this.Label5);
            this.GroupBox2.Controls.Add(this.AdvTaiKhoanCo);
            point = new Point(0x146, 0x62);
            this.GroupBox2.Location = point;
            this.GroupBox2.Name = "GroupBox2";
            size = new Size(0x13e, 0x88);
            this.GroupBox2.Size = size;
            this.GroupBox2.TabIndex = 0x98;
            this.GroupBox2.TabStop = false;
            this.GroupBox2.Text = "Vế c\x00f3";
            this.Label2.AutoSize = true;
            point = new Point(4, 0x1c);
            this.Label2.Location = point;
            this.Label2.Name = "Label2";
            size = new Size(0x37, 13);
            this.Label2.Size = size;
            this.Label2.TabIndex = 120;
            this.Label2.Text = "T\x00e0i khoản";
            this.advHopDongCo.LoaiDanhMuc = ADVList.ListDanhMuc.HopDong;
            point = new Point(0x47, 0x6a);
            this.advHopDongCo.Location = point;
            this.advHopDongCo.Name = "advHopDongCo";
            this.advHopDongCo.ReadOnly = true;
            size = new Size(0xf4, 20);
            this.advHopDongCo.Size = size;
            this.advHopDongCo.TabIndex = 0x74;
            this.advHopDongCo.UpperText = true;
            this.advHopDongCo.Value = "";
            this.advHopDongCo.WidthCode = 80;
            this.advSanPhamCo.LoaiDanhMuc = ADVList.ListDanhMuc.SanPham;
            point = new Point(0x47, 0x4f);
            this.advSanPhamCo.Location = point;
            this.advSanPhamCo.Name = "advSanPhamCo";
            this.advSanPhamCo.ReadOnly = true;
            size = new Size(0xf4, 20);
            this.advSanPhamCo.Size = size;
            this.advSanPhamCo.TabIndex = 0x73;
            this.advSanPhamCo.UpperText = true;
            this.advSanPhamCo.Value = "";
            this.advSanPhamCo.WidthCode = 80;
            this.AdvBoPhanCo.LoaiDanhMuc = ADVList.ListDanhMuc.BoPhan;
            point = new Point(0x47, 0x34);
            this.AdvBoPhanCo.Location = point;
            this.AdvBoPhanCo.Name = "AdvBoPhanCo";
            this.AdvBoPhanCo.ReadOnly = true;
            size = new Size(0xf4, 20);
            this.AdvBoPhanCo.Size = size;
            this.AdvBoPhanCo.TabIndex = 0x72;
            this.AdvBoPhanCo.UpperText = true;
            this.AdvBoPhanCo.Value = "";
            this.AdvBoPhanCo.WidthCode = 80;
            this.Label3.AutoSize = true;
            point = new Point(5, 0x6d);
            this.Label3.Location = point;
            this.Label3.Name = "Label3";
            size = new Size(0x37, 13);
            this.Label3.Size = size;
            this.Label3.TabIndex = 0x77;
            this.Label3.Text = "Hợp đồng";
            this.Label4.AutoSize = true;
            point = new Point(5, 0x52);
            this.Label4.Location = point;
            this.Label4.Name = "Label4";
            size = new Size(0x37, 13);
            this.Label4.Size = size;
            this.Label4.TabIndex = 0x76;
            this.Label4.Text = "Sản phẩm";
            this.Label5.AutoSize = true;
            point = new Point(5, 0x37);
            this.Label5.Location = point;
            this.Label5.Name = "Label5";
            size = new Size(0x2f, 13);
            this.Label5.Size = size;
            this.Label5.TabIndex = 0x75;
            this.Label5.Text = "Bộ phận";
            this.AdvTaiKhoanCo.Conditions = "";
            this.AdvTaiKhoanCo.DefaultValue = "";
            this.AdvTaiKhoanCo.FieldNameFilter = "";
            this.AdvTaiKhoanCo.KeyFilter = "";
            point = new Point(0x47, 0x19);
            this.AdvTaiKhoanCo.Location = point;
            Padding padding = new Padding(0);
            this.AdvTaiKhoanCo.Margin = padding;
            this.AdvTaiKhoanCo.Name = "AdvTaiKhoanCo";
            this.AdvTaiKhoanCo.OnlyDigit = false;
            this.AdvTaiKhoanCo.ReadOnly = true;
            size = new Size(0xf4, 20);
            this.AdvTaiKhoanCo.Size = size;
            this.AdvTaiKhoanCo.TabIndex = 0x71;
            this.AdvTaiKhoanCo.UpperText = true;
            this.AdvTaiKhoanCo.Value = "";
            this.AdvTaiKhoanCo.WithCode = 80;
            this.GroupBox1.Controls.Add(this.Label1);
            this.GroupBox1.Controls.Add(this.AdvHopDongNo);
            this.GroupBox1.Controls.Add(this.AdvSanPhamNo);
            this.GroupBox1.Controls.Add(this.AdvBoPhanNo);
            this.GroupBox1.Controls.Add(this.Label8);
            this.GroupBox1.Controls.Add(this.Label7);
            this.GroupBox1.Controls.Add(this.Label6);
            this.GroupBox1.Controls.Add(this.AdvTaiKhoanNo);
            point = new Point(4, 0x62);
            this.GroupBox1.Location = point;
            this.GroupBox1.Name = "GroupBox1";
            size = new Size(0x13f, 0x88);
            this.GroupBox1.Size = size;
            this.GroupBox1.TabIndex = 0x97;
            this.GroupBox1.TabStop = false;
            this.GroupBox1.Text = "Vế nợ";
            this.Label1.AutoSize = true;
            point = new Point(4, 0x1b);
            this.Label1.Location = point;
            this.Label1.Name = "Label1";
            size = new Size(0x37, 13);
            this.Label1.Size = size;
            this.Label1.TabIndex = 0x70;
            this.Label1.Text = "T\x00e0i khoản";
            this.AdvHopDongNo.LoaiDanhMuc = ADVList.ListDanhMuc.HopDong;
            point = new Point(0x47, 0x69);
            this.AdvHopDongNo.Location = point;
            this.AdvHopDongNo.Name = "AdvHopDongNo";
            this.AdvHopDongNo.ReadOnly = false;
            size = new Size(0xf4, 20);
            this.AdvHopDongNo.Size = size;
            this.AdvHopDongNo.TabIndex = 0x7a;
            this.AdvHopDongNo.UpperText = true;
            this.AdvHopDongNo.Value = "";
            this.AdvHopDongNo.WidthCode = 80;
            this.AdvSanPhamNo.LoaiDanhMuc = ADVList.ListDanhMuc.SanPham;
            point = new Point(0x47, 0x4e);
            this.AdvSanPhamNo.Location = point;
            this.AdvSanPhamNo.Name = "AdvSanPhamNo";
            this.AdvSanPhamNo.ReadOnly = false;
            size = new Size(0xf4, 20);
            this.AdvSanPhamNo.Size = size;
            this.AdvSanPhamNo.TabIndex = 0x79;
            this.AdvSanPhamNo.UpperText = true;
            this.AdvSanPhamNo.Value = "";
            this.AdvSanPhamNo.WidthCode = 80;
            this.AdvBoPhanNo.LoaiDanhMuc = ADVList.ListDanhMuc.BoPhan;
            point = new Point(0x47, 0x33);
            this.AdvBoPhanNo.Location = point;
            this.AdvBoPhanNo.Name = "AdvBoPhanNo";
            this.AdvBoPhanNo.ReadOnly = false;
            size = new Size(0xf4, 20);
            this.AdvBoPhanNo.Size = size;
            this.AdvBoPhanNo.TabIndex = 120;
            this.AdvBoPhanNo.UpperText = true;
            this.AdvBoPhanNo.Value = "";
            this.AdvBoPhanNo.WidthCode = 80;
            this.Label8.AutoSize = true;
            point = new Point(5, 0x6c);
            this.Label8.Location = point;
            this.Label8.Name = "Label8";
            size = new Size(0x37, 13);
            this.Label8.Size = size;
            this.Label8.TabIndex = 0x6f;
            this.Label8.Text = "Hợp đồng";
            this.Label7.AutoSize = true;
            point = new Point(5, 0x51);
            this.Label7.Location = point;
            this.Label7.Name = "Label7";
            size = new Size(0x37, 13);
            this.Label7.Size = size;
            this.Label7.TabIndex = 110;
            this.Label7.Text = "Sản phẩm";
            this.Label6.AutoSize = true;
            point = new Point(5, 0x36);
            this.Label6.Location = point;
            this.Label6.Name = "Label6";
            size = new Size(0x2f, 13);
            this.Label6.Size = size;
            this.Label6.TabIndex = 0x6d;
            this.Label6.Text = "Bộ phận";
            this.AdvTaiKhoanNo.Conditions = "";
            this.AdvTaiKhoanNo.DefaultValue = "";
            this.AdvTaiKhoanNo.FieldNameFilter = "Left(SoTaiKhoan,1)";
            this.AdvTaiKhoanNo.KeyFilter = "6";
            point = new Point(0x47, 0x18);
            this.AdvTaiKhoanNo.Location = point;
            padding = new Padding(0);
            this.AdvTaiKhoanNo.Margin = padding;
            this.AdvTaiKhoanNo.Name = "AdvTaiKhoanNo";
            this.AdvTaiKhoanNo.OnlyDigit = false;
            this.AdvTaiKhoanNo.ReadOnly = false;
            size = new Size(0xf4, 20);
            this.AdvTaiKhoanNo.Size = size;
            this.AdvTaiKhoanNo.TabIndex = 0x77;
            this.AdvTaiKhoanNo.UpperText = true;
            this.AdvTaiKhoanNo.Value = "";
            this.AdvTaiKhoanNo.WithCode = 80;
            this.Label9.AutoSize = true;
            point = new Point(0x19d, 0x44);
            this.Label9.Location = point;
            this.Label9.Name = "Label9";
            size = new Size(0x74, 13);
            this.Label9.Size = size;
            this.Label9.TabIndex = 150;
            this.Label9.Text = "Trị gi\x00e1 ph\x00e2n bổ / th\x00e1ng";
            this.TxtTriGiaPhanBo.FormatType = FormatTypeEnum.StandardNumber;
            point = new Point(530, 0x40);
            this.TxtTriGiaPhanBo.Location = point;
            this.TxtTriGiaPhanBo.Name = "TxtTriGiaPhanBo";
            this.TxtTriGiaPhanBo.ReadOnly = true;
            size = new Size(0x6d, 20);
            this.TxtTriGiaPhanBo.Size = size;
            this.TxtTriGiaPhanBo.TabIndex = 0x76;
            this.TxtTriGiaPhanBo.Tag = null;
            this.TxtTriGiaPhanBo.TextAlign = HorizontalAlignment.Right;
            this.TxtTriGiaPhanBo.VisibleButtons = DropDownControlButtonFlags.None;
            this.Label23.AutoSize = true;
            point = new Point(0xc6, 0x2a);
            this.Label23.Location = point;
            this.Label23.Name = "Label23";
            size = new Size(0x5c, 13);
            this.Label23.Size = size;
            this.Label23.TabIndex = 0x94;
            this.Label23.Text = "Số th\x00e1ng ph\x00e2n bổ";
            this.Label12.AutoSize = true;
            point = new Point(0xd8, 0x44);
            this.Label12.Location = point;
            this.Label12.Name = "Label12";
            size = new Size(0x27, 13);
            this.Label12.Size = size;
            this.Label12.TabIndex = 0x76;
            this.Label12.Text = "C\x00f2n lại";
            this.txtConLai.FormatType = FormatTypeEnum.StandardNumber;
            point = new Point(0x124, 0x40);
            this.txtConLai.Location = point;
            this.txtConLai.Name = "txtConLai";
            this.txtConLai.ReadOnly = true;
            size = new Size(0x6f, 20);
            this.txtConLai.Size = size;
            this.txtConLai.TabIndex = 0x75;
            this.txtConLai.Tag = null;
            this.txtConLai.TextAlign = HorizontalAlignment.Right;
            this.txtConLai.VisibleButtons = DropDownControlButtonFlags.None;
            this.Label11.AutoSize = true;
            point = new Point(5, 70);
            this.Label11.Location = point;
            this.Label11.Name = "Label11";
            size = new Size(0x3f, 13);
            this.Label11.Size = size;
            this.Label11.TabIndex = 130;
            this.Label11.Text = "Đ\x00e3 ph\x00e2n bổ";
            point = new Point(0x60, 0x26);
            this.TxtThangBatDau.Location = point;
            this.TxtThangBatDau.Mask = "##/####";
            this.TxtThangBatDau.Name = "TxtThangBatDau";
            size = new Size(0x36, 20);
            this.TxtThangBatDau.Size = size;
            this.TxtThangBatDau.TabIndex = 0x72;
            this.Label10.AutoSize = true;
            point = new Point(4, 0x2b);
            this.Label10.Location = point;
            this.Label10.Name = "Label10";
            size = new Size(0x59, 13);
            this.Label10.Size = size;
            this.Label10.TabIndex = 0x71;
            this.Label10.Text = "Ph\x00e2n bổ từ th\x00e1ng";
            this.GroupBox4.BackColor = Color.Transparent;
            this.GroupBox4.Controls.Add(this.TxtDienGiai);
            this.GroupBox4.Controls.Add(this.Label17);
            this.GroupBox4.Controls.Add(this.TxtNgayChungTu);
            this.GroupBox4.Controls.Add(this.TxtSoChungTu);
            this.GroupBox4.Controls.Add(this.Label13);
            this.GroupBox4.Controls.Add(this.TxtSoPhatSinh);
            this.GroupBox4.Controls.Add(this.Label14);
            this.GroupBox4.Controls.Add(this.Label16);
            point = new Point(4, 6);
            this.GroupBox4.Location = point;
            this.GroupBox4.Name = "GroupBox4";
            size = new Size(0x288, 0x61);
            this.GroupBox4.Size = size;
            this.GroupBox4.TabIndex = 0x17;
            this.GroupBox4.TabStop = false;
            this.GroupBox4.Text = "Chứng từ gốc";
            point = new Point(0x60, 0x37);
            this.TxtDienGiai.Location = point;
            this.TxtDienGiai.Name = "TxtDienGiai";
            this.TxtDienGiai.ReadOnly = true;
            size = new Size(0x220, 20);
            this.TxtDienGiai.Size = size;
            this.TxtDienGiai.TabIndex = 0x7e;
            this.Label17.AutoSize = true;
            point = new Point(4, 0x3a);
            this.Label17.Location = point;
            this.Label17.Name = "Label17";
            size = new Size(0x30, 13);
            this.Label17.Size = size;
            this.Label17.TabIndex = 0x7d;
            this.Label17.Text = "Diễn giải";
            this.TxtNgayChungTu.Enabled = false;
            this.TxtNgayChungTu.Format = DateTimePickerFormat.Short;
            point = new Point(0x124, 0x1c);
            this.TxtNgayChungTu.Location = point;
            this.TxtNgayChungTu.Name = "TxtNgayChungTu";
            size = new Size(0x6f, 20);
            this.TxtNgayChungTu.Size = size;
            this.TxtNgayChungTu.TabIndex = 0x7c;
            point = new Point(0x60, 0x1c);
            this.TxtSoChungTu.Location = point;
            this.TxtSoChungTu.Name = "TxtSoChungTu";
            this.TxtSoChungTu.ReadOnly = true;
            size = new Size(0x6d, 20);
            this.TxtSoChungTu.Size = size;
            this.TxtSoChungTu.TabIndex = 0x7b;
            this.Label13.AutoSize = true;
            point = new Point(0x1a2, 0x20);
            this.Label13.Location = point;
            this.Label13.Name = "Label13";
            size = new Size(0x42, 13);
            this.Label13.Size = size;
            this.Label13.TabIndex = 0x76;
            this.Label13.Text = "Số ph\x00e1t sinh";
            this.TxtSoPhatSinh.FormatType = FormatTypeEnum.StandardNumber;
            point = new Point(530, 0x1d);
            this.TxtSoPhatSinh.Location = point;
            this.TxtSoPhatSinh.Name = "TxtSoPhatSinh";
            this.TxtSoPhatSinh.ReadOnly = true;
            size = new Size(0x6d, 20);
            this.TxtSoPhatSinh.Size = size;
            this.TxtSoPhatSinh.TabIndex = 0x75;
            this.TxtSoPhatSinh.Tag = null;
            this.TxtSoPhatSinh.TextAlign = HorizontalAlignment.Right;
            this.TxtSoPhatSinh.VisibleButtons = DropDownControlButtonFlags.None;
            this.Label14.AutoSize = true;
            point = new Point(0xf7, 0x1f);
            this.Label14.Location = point;
            this.Label14.Name = "Label14";
            size = new Size(0x20, 13);
            this.Label14.Size = size;
            this.Label14.TabIndex = 0x74;
            this.Label14.Text = "Ng\x00e0y";
            this.Label16.AutoSize = true;
            point = new Point(4, 0x1f);
            this.Label16.Location = point;
            this.Label16.Name = "Label16";
            size = new Size(0x41, 13);
            this.Label16.Size = size;
            this.Label16.TabIndex = 0x70;
            this.Label16.Text = "Số chứng từ";
            this.CmdCancel.DialogResult = DialogResult.Cancel;
            this.CmdCancel.Image = (Image) manager.GetObject("CmdCancel.Image");
            this.CmdCancel.ImageAlign = ContentAlignment.MiddleLeft;
            point = new Point(0x23d, 0x16e);
            this.CmdCancel.Location = point;
            this.CmdCancel.Name = "CmdCancel";
            size = new Size(0x4f, 0x18);
            this.CmdCancel.Size = size;
            this.CmdCancel.TabIndex = 0x19;
            this.CmdCancel.Text = "&Tho\x00e1t";
            this.CmdCancel.UseVisualStyleBackColor = true;
            this.CmdOK.Image = (Image) manager.GetObject("CmdOK.Image");
            this.CmdOK.ImageAlign = ContentAlignment.MiddleLeft;
            point = new Point(490, 0x16e);
            this.CmdOK.Location = point;
            this.CmdOK.Name = "CmdOK";
            size = new Size(0x4e, 0x18);
            this.CmdOK.Size = size;
            this.CmdOK.TabIndex = 0x18;
            this.CmdOK.Text = "&Chọn";
            this.CmdOK.UseVisualStyleBackColor = true;
            SizeF ef = new SizeF(6f, 13f);
            this.AutoScaleDimensions = ef;
            this.AutoScaleMode = AutoScaleMode.Font;
            this.BackgroundImage = ACCOUNTING.My.Resources.Resources.background;
            size = new Size(0x290, 0x18a);
            this.ClientSize = size;
            this.ControlBox = false;
            this.Controls.Add(this.CmdCancel);
            this.Controls.Add(this.CmdOK);
            this.Controls.Add(this.GroupBox4);
            this.Controls.Add(this.GroupBox3);
            this.FormBorderStyle = FormBorderStyle.FixedDialog;
            this.Name = "Frm_ChiPhiTraTruoc";
            this.StartPosition = FormStartPosition.CenterScreen;
            this.Text = "PHAN BO CHI PHI TRA TRUOC";
            this.GroupBox3.ResumeLayout(false);
            this.GroupBox3.PerformLayout();
            ((ISupportInitialize) this.txtDaPhanBo).EndInit();
            this.updSoThangPhanBo.EndInit();
            this.GroupBox2.ResumeLayout(false);
            this.GroupBox2.PerformLayout();
            this.GroupBox1.ResumeLayout(false);
            this.GroupBox1.PerformLayout();
            ((ISupportInitialize) this.TxtTriGiaPhanBo).EndInit();
            ((ISupportInitialize) this.txtConLai).EndInit();
            this.GroupBox4.ResumeLayout(false);
            this.GroupBox4.PerformLayout();
            ((ISupportInitialize) this.TxtSoPhatSinh).EndInit();
            this.ResumeLayout(false);
        }

        public void LoadData(string pKhoa)
        {
            this.objPB.Load(pKhoa);
            GLDinhNghiaPhanBo objPB = this.objPB;
            this.cFrmKhoa = pKhoa;
            this.TxtSoChungTu.Tag = objPB.KhoaChungTu;
            this.TxtSoChungTu.Text = objPB.SoChungTu;
            this.TxtNgayChungTu.Text = LVYModule.Char2Date(objPB.NgayChungTu);
            this.TxtSoPhatSinh.Value = objPB.SoPhatSinh;
            this.AdvTaiKhoanCo.Value = objPB.KhoaTaiKhoan;
            this.TxtDienGiai.Text = objPB.DienGiai;
            this.TxtThangBatDau.Text = LVYModule.sRight(objPB.ThangBatDauPhanBo, 2) + "/" + LVYModule.sLeft(objPB.ThangBatDauPhanBo, 4);
            this.updSoThangPhanBo.Value = new decimal(objPB.SoThangPhanBo);
            this.txtDaPhanBo.Value = objPB.DaPhanBo;
            this.txtConLai.Value = objPB.ConLai;
            this.TxtTriGiaPhanBo.Value = objPB.TriGiaPhanBo;
            this.AdvBoPhanCo.Value = objPB.KhoaBoPhanCo;
            this.advSanPhamCo.Value = objPB.KhoaSanPhamCo;
            this.advHopDongCo.Value = objPB.KhoaHopDongCo;
            this.AdvTaiKhoanNo.Value = objPB.KhoaTaiKhoanNo;
            this.AdvBoPhanNo.Value = objPB.KhoaBoPhanNo;
            this.AdvSanPhamNo.Value = objPB.KhoaSanPhamNo;
            this.AdvHopDongNo.Value = objPB.KhoaHopDongNo;
            objPB = null;
            if (this.objPB.DaPhanBoChiPhi(pKhoa))
            {
                this.CmdOK.Enabled = false;
            }
            else
            {
                this.CmdOK.Enabled = true;
            }
        }

        private void txtDaPhanBo_LostFocus(object sender, EventArgs e)
        {
            double num2 = Conversions.ToDouble(LVYModule.ReturnIfNull(RuntimeHelpers.GetObjectValue(this.TxtSoPhatSinh.Value), 0, modGeneral.TypeOfValue.Nothing));
            double num = Conversions.ToDouble(LVYModule.ReturnIfNull(RuntimeHelpers.GetObjectValue(this.txtDaPhanBo.Value), 0, modGeneral.TypeOfValue.Nothing));
            if (num >= num2)
            {
                LVYModule.ShowWarning(modGeneral.Tranlated("Số đ\x00e3 ph\x00e2n bổ phải nhỏ hơn số ph\x00e1t sinh!", ""));
                this.txtDaPhanBo.Value = 0;
                this.txtDaPhanBo.Focus();
            }
            this.txtConLai.Value = num2 - num;
            this.updSoThangPhanBo_ValueChanged(this.updSoThangPhanBo, e);
        }

        private void TxtThangBatDau_GotFocus(object sender, EventArgs e)
        {
            this.TxtThangBatDau.SelectAll();
        }

        private void updSoThangPhanBo_ValueChanged(object sender, EventArgs e)
        {
            double num = Conversions.ToDouble(LVYModule.ReturnIfNull(RuntimeHelpers.GetObjectValue(this.txtConLai.Value), 0, modGeneral.TypeOfValue.Nothing));
            int num2 = (int) Math.Round(Conversions.ToDouble(LVYModule.ReturnIfNull(this.updSoThangPhanBo.Value, 0, modGeneral.TypeOfValue.Nothing)));
            if (num2 == 0)
            {
                this.TxtTriGiaPhanBo.Value = 0;
            }
            else
            {
                this.TxtTriGiaPhanBo.Value = Math.Round((double) (num / ((double) num2)), 0);
            }
        }

        internal virtual ADVList AdvBoPhanCo
        {
            [DebuggerNonUserCode]
            get
            {
                return this._AdvBoPhanCo;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                this._AdvBoPhanCo = value;
            }
        }

        internal virtual ADVList AdvBoPhanNo
        {
            [DebuggerNonUserCode]
            get
            {
                return this._AdvBoPhanNo;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                this._AdvBoPhanNo = value;
            }
        }

        internal virtual ADVList advHopDongCo
        {
            [DebuggerNonUserCode]
            get
            {
                return this._advHopDongCo;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                this._advHopDongCo = value;
            }
        }

        internal virtual ADVList AdvHopDongNo
        {
            [DebuggerNonUserCode]
            get
            {
                return this._AdvHopDongNo;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                this._AdvHopDongNo = value;
            }
        }

        internal virtual ADVList advSanPhamCo
        {
            [DebuggerNonUserCode]
            get
            {
                return this._advSanPhamCo;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                this._advSanPhamCo = value;
            }
        }

        internal virtual ADVList AdvSanPhamNo
        {
            [DebuggerNonUserCode]
            get
            {
                return this._AdvSanPhamNo;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                this._AdvSanPhamNo = value;
            }
        }

        internal virtual ADVAccount AdvTaiKhoanCo
        {
            [DebuggerNonUserCode]
            get
            {
                return this._AdvTaiKhoanCo;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                this._AdvTaiKhoanCo = value;
            }
        }

        internal virtual ADVAccount AdvTaiKhoanNo
        {
            [DebuggerNonUserCode]
            get
            {
                return this._AdvTaiKhoanNo;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                this._AdvTaiKhoanNo = value;
            }
        }

        internal virtual Button CmdCancel
        {
            [DebuggerNonUserCode]
            get
            {
                return this._CmdCancel;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                EventHandler handler = new EventHandler(this.CmdCancel_Click);
                if (this._CmdCancel != null)
                {
                    this._CmdCancel.Click -= handler;
                }
                this._CmdCancel = value;
                if (this._CmdCancel != null)
                {
                    this._CmdCancel.Click += handler;
                }
            }
        }

        internal virtual Button CmdOK
        {
            [DebuggerNonUserCode]
            get
            {
                return this._CmdOK;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                EventHandler handler = new EventHandler(this.CmdOK_Click);
                if (this._CmdOK != null)
                {
                    this._CmdOK.Click -= handler;
                }
                this._CmdOK = value;
                if (this._CmdOK != null)
                {
                    this._CmdOK.Click += handler;
                }
            }
        }

        internal virtual GroupBox GroupBox1
        {
            [DebuggerNonUserCode]
            get
            {
                return this._GroupBox1;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                this._GroupBox1 = value;
            }
        }

        internal virtual GroupBox GroupBox2
        {
            [DebuggerNonUserCode]
            get
            {
                return this._GroupBox2;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                this._GroupBox2 = value;
            }
        }

        internal virtual GroupBox GroupBox3
        {
            [DebuggerNonUserCode]
            get
            {
                return this._GroupBox3;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                this._GroupBox3 = value;
            }
        }

        internal virtual GroupBox GroupBox4
        {
            [DebuggerNonUserCode]
            get
            {
                return this._GroupBox4;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                this._GroupBox4 = value;
            }
        }

        internal virtual Label Label1
        {
            [DebuggerNonUserCode]
            get
            {
                return this._Label1;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                this._Label1 = value;
            }
        }

        internal virtual Label Label10
        {
            [DebuggerNonUserCode]
            get
            {
                return this._Label10;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                this._Label10 = value;
            }
        }

        internal virtual Label Label11
        {
            [DebuggerNonUserCode]
            get
            {
                return this._Label11;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                this._Label11 = value;
            }
        }

        internal virtual Label Label12
        {
            [DebuggerNonUserCode]
            get
            {
                return this._Label12;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                this._Label12 = value;
            }
        }

        internal virtual Label Label13
        {
            [DebuggerNonUserCode]
            get
            {
                return this._Label13;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                this._Label13 = value;
            }
        }

        internal virtual Label Label14
        {
            [DebuggerNonUserCode]
            get
            {
                return this._Label14;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                this._Label14 = value;
            }
        }

        internal virtual Label Label16
        {
            [DebuggerNonUserCode]
            get
            {
                return this._Label16;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                this._Label16 = value;
            }
        }

        internal virtual Label Label17
        {
            [DebuggerNonUserCode]
            get
            {
                return this._Label17;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                this._Label17 = value;
            }
        }

        internal virtual Label Label2
        {
            [DebuggerNonUserCode]
            get
            {
                return this._Label2;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                this._Label2 = value;
            }
        }

        internal virtual Label Label23
        {
            [DebuggerNonUserCode]
            get
            {
                return this._Label23;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                this._Label23 = value;
            }
        }

        internal virtual Label Label3
        {
            [DebuggerNonUserCode]
            get
            {
                return this._Label3;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                this._Label3 = value;
            }
        }

        internal virtual Label Label4
        {
            [DebuggerNonUserCode]
            get
            {
                return this._Label4;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                this._Label4 = value;
            }
        }

        internal virtual Label Label5
        {
            [DebuggerNonUserCode]
            get
            {
                return this._Label5;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                this._Label5 = value;
            }
        }

        internal virtual Label Label6
        {
            [DebuggerNonUserCode]
            get
            {
                return this._Label6;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                this._Label6 = value;
            }
        }

        internal virtual Label Label7
        {
            [DebuggerNonUserCode]
            get
            {
                return this._Label7;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                this._Label7 = value;
            }
        }

        internal virtual Label Label8
        {
            [DebuggerNonUserCode]
            get
            {
                return this._Label8;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                this._Label8 = value;
            }
        }

        internal virtual Label Label9
        {
            [DebuggerNonUserCode]
            get
            {
                return this._Label9;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                this._Label9 = value;
            }
        }

        internal virtual C1NumericEdit txtConLai
        {
            [DebuggerNonUserCode]
            get
            {
                return this._txtConLai;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                this._txtConLai = value;
            }
        }

        internal virtual C1NumericEdit txtDaPhanBo
        {
            [DebuggerNonUserCode]
            get
            {
                return this._txtDaPhanBo;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                this._txtDaPhanBo = value;
            }
        }

        internal virtual TextBox TxtDienGiai
        {
            [DebuggerNonUserCode]
            get
            {
                return this._TxtDienGiai;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                this._TxtDienGiai = value;
            }
        }

        internal virtual DateTimePicker TxtNgayChungTu
        {
            [DebuggerNonUserCode]
            get
            {
                return this._TxtNgayChungTu;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                this._TxtNgayChungTu = value;
            }
        }

        internal virtual TextBox TxtSoChungTu
        {
            [DebuggerNonUserCode]
            get
            {
                return this._TxtSoChungTu;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                this._TxtSoChungTu = value;
            }
        }

        internal virtual C1NumericEdit TxtSoPhatSinh
        {
            [DebuggerNonUserCode]
            get
            {
                return this._TxtSoPhatSinh;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                this._TxtSoPhatSinh = value;
            }
        }

        internal virtual MaskedTextBox TxtThangBatDau
        {
            [DebuggerNonUserCode]
            get
            {
                return this._TxtThangBatDau;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                EventHandler handler = new EventHandler(this.TxtThangBatDau_GotFocus);
                if (this._TxtThangBatDau != null)
                {
                    this._TxtThangBatDau.GotFocus -= handler;
                }
                this._TxtThangBatDau = value;
                if (this._TxtThangBatDau != null)
                {
                    this._TxtThangBatDau.GotFocus += handler;
                }
            }
        }

        internal virtual C1NumericEdit TxtTriGiaPhanBo
        {
            [DebuggerNonUserCode]
            get
            {
                return this._TxtTriGiaPhanBo;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                this._TxtTriGiaPhanBo = value;
            }
        }

        internal virtual NumericUpDown updSoThangPhanBo
        {
            [DebuggerNonUserCode]
            get
            {
                return this._updSoThangPhanBo;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                EventHandler handler = new EventHandler(this.updSoThangPhanBo_ValueChanged);
                if (this._updSoThangPhanBo != null)
                {
                    this._updSoThangPhanBo.ValueChanged -= handler;
                }
                this._updSoThangPhanBo = value;
                if (this._updSoThangPhanBo != null)
                {
                    this._updSoThangPhanBo.ValueChanged += handler;
                }
            }
        }
    }
}

